<!DOCTYPE html>
<!-- saved from url=(0052)http://getbootstrap.com/docs/4.0/examples/dashboard/ -->
<html lang="en" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <title>考试项目设置管理</title>
    <!-- Bootstrap core CSS -->
    <link href="../static/asserts/css/bootstrap.min.css" th:href="@{/asserts/css/bootstrap.min.css}" rel="stylesheet">
    <script src="http://libs.baidu.com/bootstrap/3.0.3/js/bootstrap.js"></script>
    <link href="http://libs.baidu.com/bootstrap/3.0.3/css/bootstrap.css" rel="stylesheet">
    <!-- Custom styles for this template -->
    <link href="../static/asserts/css/dashboard.css" th:href="@{/asserts/css/dashboard.css}" rel="stylesheet">
    <style type="text/css">
        /* Chart.js */

        @-webkit-keyframes chartjs-render-animation {
            from {
                opacity: 0.99
            }
            to {
                opacity: 1
            }
        }

        @keyframes chartjs-render-animation {
            from {
                opacity: 0.99
            }
            to {
                opacity: 1
            }
        }

        .chartjs-render-monitor {
            -webkit-animation: chartjs-render-animation 0.001s;
            animation: chartjs-render-animation 0.001s;
        }
    </style>
</head>

<body>
<div th:replace="sidbar::#topbar"></div>

<div class="container-fluid">
    <div class="row">
        <div th:replace="sidbar::#sbar"></div>

        <main role="main" class="col-md-9 ml-sm-auto col-lg-10 pt-3 px-4">
            <div class="chartjs-size-monitor"
                 style="position: absolute; left: 0px; top: 0px; right: 0px; bottom: 0px; overflow: hidden; pointer-events: none; visibility: hidden; z-index: -1;">
                <div class="chartjs-size-monitor-expand"
                     style="position:absolute;left:0;top:0;right:0;bottom:0;overflow:hidden;pointer-events:none;visibility:hidden;z-index:-1;">
                    <div style="position:absolute;width:1000000px;height:1000000px;left:0;top:0"></div>
                </div>
                <div class="chartjs-size-monitor-shrink"
                     style="position:absolute;left:0;top:0;right:0;bottom:0;overflow:hidden;pointer-events:none;visibility:hidden;z-index:-1;">
                    <div style="position:absolute;width:200%;height:200%;left:0; top:0"></div>
                </div>
            </div>

            <div class="container-fluid" style="border:gray solid 1px ;background: rgba(153,144,191,0.14)">
                <div style="text-align: center;margin: 10px 0;">
                    <h2>考试项目设置管理</h2>
                </div>
                <div class="row">

                    <div class="col-md-2 ">
                        <a th:href="@{/exam/list}" class="btn btn-info">查看全部考试科目</a>
                    </div>

                    <div class="col-md-3 ">
                        <form th:action="@{/exam/queryCE}" class="form-inline" method="post">
                            学院名称： <select class="col-sm-6" name="id">
                            <option th:each="col:${colleges}" th:selected="${col.getId()==id}" th:value="${col.getId()}"
                                    th:text="${col.getName()}">1
                            </option>
                        </select>
                            <input type="submit" value="查询" class="btn btn-success">
                        </form>
                    </div>


                    <div class="col-md-4 ">
                        <form th:action="@{/exam/list}" method="post">
                            科目名字：<input type="text" name="subjects">
                            <input type="submit" value="查询" class="btn btn-success">
                        </form>
                    </div>
                    <div class="col-md-2">
                        <a th:href="@{/toIE}" class="btn btn-warning">添加考试科目</a>
                    </div>
                </div>


                <div th:if="${bj!=null}"
                     style="font-size: large;text-align: center;border: 1px gray solid;background: #d2ffa9">
                    [[${bj}]]成功！考试信息： <br>
                    考试编号：
                    <div th:text="${exam.getId()}"></div>
                    考试科目：
                    <div th:text="${exam.getSubjects()}"></div>
                    考试日期：
                    <div th:text="${#dates.format(exam.getEDate(),'yyyy-MM-dd')}"></div>
                    考试学分：
                    <div th:text="${exam.getScore()}"></div>
                    考试时长：
                    <div th:text="${exam.getTime()}"></div>
                </div>
                <div id="bodyy" th:if="${pageInfoL!=null}">
                    <!--                    <button id="btn" th:onclick="stu(1)">bb</button>-->
                    <table class="table table-bordered">
                        <thead>
                        <tr>
                            <th>考试编号</th>
                            <th>考试科目</th>
                            <th>考试日期</th>
                            <th>考试学分</th>
                            <th>考试时长</th>
                            <th>操作</th>
                        </tr>
                        </thead>
                        <tbody>
                        <tr th:each="its,a:${pageInfoL.list}">

                            <td class="border-primary" th:text="${its.getId()}">考试编号</td>
                            <td class="border-success" th:text="${its.getSubjects()}">考试科目</td>
                            <td class="border-primary"  th:text="${#dates.format(its.getEDate(),'yyyy-MM-dd')}">考试日期</td>
                            <td class="border-danger"th:text="${its.getScore()}">考试学分</td>
                            <td class="border-info" th:text="${its.getTime()}+'分钟'">考试时长</td>
                            <td class="warning">
                                <a class="btn btn-outline-warning" th:href="@{/toUE(id=${its.getId()})}" title="修改课程的信息，会影响到所有考这门考试的学院">修改</a>
                                &nbsp; |&nbsp;<a class="btn btn-outline-danger"
                                                 th:href="@{/exam/delete(id=${its.getId()})}" title="危！你删除这门课会同时删除这门课与某些学院的联系">删除</a>
                            </td>
                        </tr>
                        </tbody>
                    </table>

                    <div class="col-md-3">
                        当前[[${pageInfoL.pageNum}]]页,总共[[${pageInfoL.pages}]]页,总[[${pageInfoL.total}]]条记录
                    </div>

                    <!--                   查询全部-->
                    <nav aria-label="Page navigation" th:if="${type=='queryAll'}" style="text-align: center">
                        <ul class="pagination pagination-lg">
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(pageNum= 1)}">
                                    <span aria-hidden="true">首页</span>
                                </a>
                            </li>
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(pageNum=${pageInfoL.pageNum -1})}"
                                   th:if="${pageInfoL.hasPreviousPage}" aria-label="Next">
                                    <span aria-hidden="true">&laquo;</span>
                                </a>
                                <a th:href="@{${#request.getRequestURI()}(pageNum=1)}"
                                   th:if="${pageInfoL.hasPreviousPage==false}" aria-label="Next">
                                    <span aria-hidden="true">&laquo;</span>
                                </a>
                            </li>
                        </ul>
                        <ul class="pagination pagination-lg" th:each="na:${pageInfoL.navigatepageNums}">
                            <li><a th:href="@{${#request.getRequestURI()}(pageNum=${na})}"
                                   th:if="${pageInfoL.pageNum!=na}"
                                   th:text="${na}"></a></li>
                            <li th:class="active"><a th:class="active" th:href="@{#}" th:if="${pageInfoL.pageNum==na}"
                                                     th:text="${na}"></a></li>
                        </ul>
                        <ul class="pagination pagination-lg">
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(pageNum=${pageInfoL.pageNum +1})}"
                                   th:if="${pageInfoL.hasNextPage}" aria-label="Next">
                                    <span aria-hidden="true">&raquo;</span>
                                </a>
                                <a th:href="@{${#request.getRequestURI()}(pageNum=${pageInfoL.pages})}"
                                   th:if="${pageInfoL.hasNextPage==false}" aria-label="Next">
                                    <span aria-hidden="true">&raquo;</span>
                                </a>
                            </li>
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(pageNum=${pageInfoL.pages})}"
                                   aria-label="Next">
                                    <span aria-hidden="true">末页</span>
                                </a>
                            </li>
                        </ul>
                    </nav>
                    <!--                    根据专业查询-->
                    <nav aria-label="Page navigation" th:if="${type=='querySu'}" style="text-align: center">
                        <ul class="pagination pagination-lg">
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(subjects=${su},pageNum=1)}">
                                    <span aria-hidden="true">首页</span>
                                </a>
                            </li>
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(subjects=${su},pageNum=${pageInfoL.pageNum -1})}"
                                   th:if="${pageInfoL.hasPreviousPage}" aria-label="Next">
                                    <span aria-hidden="true">&laquo;</span>
                                </a>
                                <a th:href="@{${#request.getRequestURI()}(subjects=${su},pageNum=1)}"
                                   th:if="${pageInfoL.hasPreviousPage==false}" aria-label="Next">
                                    <span aria-hidden="true">&laquo;</span>
                                </a>
                            </li>
                        </ul>
                        <ul class="pagination pagination-lg" th:each="na:${pageInfoL.navigatepageNums}">
                            <li><a th:href="@{${#request.getRequestURI()}(subjects=${su},pageNum=${na})}"
                                   th:if="${pageInfoL.pageNum!=na}"
                                   th:text="${na}"></a></li>
                            <li th:class="active"><a th:class="active" th:href="@{#}" th:if="${pageInfoL.pageNum==na}"
                                                     th:text="${na}"></a></li>
                        </ul>
                        <ul class="pagination pagination-lg">
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(subjects=${su},pageNum=${pageInfoL.pageNum +1})}"
                                   th:if="${pageInfoL.hasNextPage}" aria-label="Next">
                                    <span aria-hidden="true">&raquo;</span>
                                </a>
                                <a th:href="@{${#request.getRequestURI()}(subjects=${su},pageNum=${pageInfoL.pages})}"
                                   th:if="${pageInfoL.hasNextPage==false}" aria-label="Next">
                                    <span aria-hidden="true">&raquo;</span>
                                </a>
                            </li>
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(subjects=${su},pageNum=${pageInfoL.pages})}"
                                   aria-label="Next">
                                    <span aria-hidden="true">末页</span>
                                </a>
                            </li>
                        </ul>
                    </nav>
                    <!--                    根据学院查询-->
                    <nav aria-label="Page navigation" th:if="${type=='queryCE'}" style="text-align: center">
                        <ul class="pagination pagination-lg">
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(id=${id},pageNum=1)}">
                                    <span aria-hidden="true">首页</span>
                                </a>
                            </li>
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(id=${id},pageNum=${pageInfoL.pageNum -1})}"
                                   th:if="${pageInfoL.hasPreviousPage}" aria-label="Next">
                                    <span aria-hidden="true">&laquo;</span>
                                </a>
                                <a th:href="@{${#request.getRequestURI()}(id=${id},pageNum=1)}"
                                   th:if="${pageInfoL.hasPreviousPage==false}" aria-label="Next">
                                    <span aria-hidden="true">&laquo;</span>
                                </a>
                            </li>
                        </ul>
                        <ul class="pagination pagination-lg" th:each="na:${pageInfoL.navigatepageNums}">
                            <li><a th:href="@{${#request.getRequestURI()}(id=${id},pageNum=${na})}"
                                   th:if="${pageInfoL.pageNum!=na}"
                                   th:text="${na}"></a></li>
                            <li th:class="active"><a th:class="active" th:href="@{#}" th:if="${pageInfoL.pageNum==na}"
                                                     th:text="${na}"></a></li>
                        </ul>
                        <ul class="pagination pagination-lg">
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(id=${id},pageNum=${pageInfoL.pageNum +1})}"
                                   th:if="${pageInfoL.hasNextPage}" aria-label="Next">
                                    <span aria-hidden="true">&raquo;</span>
                                </a>
                                <a th:href="@{${#request.getRequestURI()}(id=${id},pageNum=${pageInfoL.pages})}"
                                   th:if="${pageInfoL.hasNextPage==false}" aria-label="Next">
                                    <span aria-hidden="true">&raquo;</span>
                                </a>
                            </li>
                            <li>
                                <a th:href="@{${#request.getRequestURI()}(id=${id},pageNum=${pageInfoL.pages})}"
                                   aria-label="Next">
                                    <span aria-hidden="true">末页</span>
                                </a>
                            </li>
                        </ul>
                    </nav>
                </div>

            </div>

        </main>
    </div>
</div>

<script>


</script>
</body>

</html>